<?php
/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2016/2/25
 * Time: 13:29
 */
try{
    include_once "sms.php";
    $s=new sms();
    if($_GET['type']=="sendcheck") {
        var_dump($s->sendcheck("13687617749", "reg", 520804101));
    }
    else if($_GET['type']=="check"){
        var_dump($s->check("13687617749","reg",$_GET['code']));
    }
    else if($_GET['type']=='send'){
        var_dump($s->send("13687617749","reg","2729"));
    }
    else{
        print("no type");
    }
    var_dump("ok");
}
catch(Exception $e){
    var_dump($e);
}